package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.SysTrackingMapper;
import com.ruoyi.system.domain.SysTracking;
import com.ruoyi.system.service.ISysTrackingService;

/**
 * 实施跟踪Service业务层处理
 * 
 * @author riddou
 * @date 2022-04-19
 */
@Service
public class SysTrackingServiceImpl implements ISysTrackingService 
{
    @Autowired
    private SysTrackingMapper sysTrackingMapper;

    /**
     * 查询实施跟踪
     * 
     * @param trackId 实施跟踪主键
     * @return 实施跟踪
     */
    @Override
    public SysTracking selectSysTrackingByTrackId(Long trackId)
    {
        return sysTrackingMapper.selectSysTrackingByTrackId(trackId);
    }

    /**
     * 查询实施跟踪列表
     * 
     * @param sysTracking 实施跟踪
     * @return 实施跟踪
     */
    @Override
    public List<SysTracking> selectSysTrackingList(SysTracking sysTracking)
    {
        return sysTrackingMapper.selectSysTrackingList(sysTracking);
    }

    /**
     * 新增实施跟踪
     * 
     * @param sysTracking 实施跟踪
     * @return 结果
     */
    @Override
    public int insertSysTracking(SysTracking sysTracking)
    {
        sysTracking.setCreateTime(DateUtils.getNowDate());
        return sysTrackingMapper.insertSysTracking(sysTracking);
    }

    /**
     * 修改实施跟踪
     * 
     * @param sysTracking 实施跟踪
     * @return 结果
     */
    @Override
    public int updateSysTracking(SysTracking sysTracking)
    {
        return sysTrackingMapper.updateSysTracking(sysTracking);
    }

    /**
     * 批量删除实施跟踪
     * 
     * @param trackIds 需要删除的实施跟踪主键
     * @return 结果
     */
    @Override
    public int deleteSysTrackingByTrackIds(Long[] trackIds)
    {
        return sysTrackingMapper.deleteSysTrackingByTrackIds(trackIds);
    }

    /**
     * 删除实施跟踪信息
     * 
     * @param trackId 实施跟踪主键
     * @return 结果
     */
    @Override
    public int deleteSysTrackingByTrackId(Long trackId)
    {
        return sysTrackingMapper.deleteSysTrackingByTrackId(trackId);
    }
}
